/**
 * unmonitor_instances.java
 * ************************** 
 * @date May 28, 2011
 * @author Michele Tamburini
 * 
 * **************************
 */
package infrastructureAPI.scripts.monitorTools;

import infrastructureAPI.ResponseException;
import infrastructureAPI.APIMessages.ResponseMessage;
import infrastructureAPI.algorithms.monitorTools.UnmonitorInstances;
import infrastructureAPI.backendGate.APIScript;
import infrastructureAPI.backendGate.GeneralScript;

/**
 * Description: 
 *
 */
public class unmonitor_instances extends GeneralScript {

	/**
	 * @param args
	 */
	public unmonitor_instances(String[] args) {
		super(args);
	}

	@Override
	public void checkNotGeneralOptionalParameters() {
		// nothing to do for this script
	}

	@Override
	public void composeMandatoryParameters() {
		// nothing to do for this script
	}

	@Override
	public APIScript instantiateAPIScript() {
		return new UnmonitorInstances(requester);
	}

	@Override
	public boolean verifyMandatoryParameters() {
		return true;
	}

	@Override
	public void waitingIncomingResposes() {
		ResponseMessage responseMsg = waitingOneIncomingResponse();
		try {
			Object obj = responseMsg.getAPIResponse().getResponse();
			System.out.println("Received response: "+obj);
		} catch (ResponseException e) {
			e.printStackTrace();
		}
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		unmonitor_instances unmonitor = new unmonitor_instances(args);
	}

}
